<?php
namespace Amis\form;
class InputSubForm extends FormItem
{
    public string $type = 'input-sub-form';

    public function multiple(bool $multiple = false)
    {
        $this->multiple = $multiple;
        return $this;
    }

    public function labelField(string $labelField)
    {
        $this->labelField = $labelField;
        return $this;
    }

    public function btnLabel($btnLabel)
    {
        $this->btnLabel = $btnLabel;
        return $this;
    }

    public function minLength(int $minLength)
    {
        $this->minLength = $minLength;
        return $this;
    }

    public function maxLength(int $maxLength)
    {
        $this->maxLength = $maxLength;
        return $this;
    }

    public function draggable(bool $draggable = false)
    {
        $this->draggable = $draggable;
        return $this;
    }

    public function addable(bool $addable = false)
    {
        $this->addable = $addable;
        return $this;
    }

    public function removable(bool $removable)
    {
        $this->removable = $removable;
        return $this;
    }

    public function addButtonClassName(string $addButtonClassName)
    {
        $this->addButtonClassName = $addButtonClassName;
        return $this;
    }

    public function itemClassName(string $itemClassName)
    {
        $this->itemClassName = $itemClassName;
        return $this;
    }

    public function itemsClassName(string $itemsClassName)
    {
        $this->itemsClassName = $itemsClassName;
        return $this;
    }

    public function form(Form $form)
    {
        $this->form = $form;
        return $this;
    }

    public function addButtonText(string $addButtonText)
    {
        $this->addButtonText = $addButtonText;
        return $this;
    }

    public function showErrorMsg(bool $showErrorMsg = true)
    {
        $this->showErrorMsg = $showErrorMsg;
        return $this;
    }
}